/**
 * @description 列表页面
 */

import React, { useEffect, useState } from "react"

import AbPagination from '@/PageCompnents/Pagination'
import CategoryList from "../Category"
import ListSearch from "../List/Components/ListSearch"
// import ListList from "./Components/ListList"
import ListHot from "@/PageCompnents/Hot/ListHot"
import ListRecommend from "./ListRecommend"

import GoodListEntry from "@/views/2025/Front/PageWrapper/Components/GoodList"

function NewslistPage({ newslist, paginationBase }) {


  return (

    <div className="newslist">

      {/* 分类 */}
      <CategoryList limit={newslist.category.base.limit} />

      {/* 搜索 */}
      <ListSearch base={newslist.newssearch.base} className='newssearch' />

      {/* 排序 */}

      {/* 列表 */}
      <div className="newslistlist">
        {/* 商品展示。 根据不同type渲染不同样式的组件 */}
        <GoodListEntry base={newslist.newslistlist.base} />
      </div>

      {/* 分页 */}
      <AbPagination paginationBase={paginationBase} />

      {/* 热门 */}
      <ListHot base={newslist.newslisthot.base} className="newslisthot" />

      {/* 最新动态 */}
      <ListRecommend base={newslist.newslistrecommend.base} className="newslistrecommend" />

    </div >
  )
}

export default React.memo(NewslistPage)